package cn.maihe.elg.operation.centers.quanzhou.dto.handler;

import cn.maihe.elg.operation.centers.epoint.dto.EpointBaseRespDTO;
import cn.maihe.elg.operation.centers.quanzhou.dto.QuanzhouBaseRespDTO;
import lombok.Getter;
import lombok.Setter;

/**
 * @Description 泉州中心投保申请响应DTO
 * @Author Generated
 * @Date 2025/01/21
 */
@Getter
@Setter
public class QuanzhouApplyRespDTO extends EpointBaseRespDTO {
    
    /**
     * 跳转链接，跳转到金融机构核心系统
     */
    private String payurl;
    
    public QuanzhouApplyRespDTO() {
        super();
    }
    
    public QuanzhouApplyRespDTO(String code, String message, String payurl) {
        super(code, message);
        this.payurl = payurl;
    }
    
    public static QuanzhouApplyRespDTO success(String message, String payurl) {
        QuanzhouApplyRespDTO resp = new QuanzhouApplyRespDTO("1", message, payurl);
        resp.setData(new PayData(payurl));
        return resp;
    }

    private void setData(PayData payData) {

    }

    public static QuanzhouApplyRespDTO failure(String message) {
        return new QuanzhouApplyRespDTO("0", message, null);
    }
    
    @Getter
    @Setter
    public static class PayData {
        private String payurl;
        
        public PayData(String payurl) {
            this.payurl = payurl;
        }
    }
}